-module(world).
-compile(export_all).

-record(world, {channel, players = [], events = []}).

new(Channel) ->
    #world{channel = Channel}.
channel(World) ->
    World#world.channel.
channel(World, Channel) ->
    World#world{channel = Channel}.
players(World) ->
    World#world.players.
players(World, Players) ->
    World#world{players = Players}.
events(World) ->
    World#world.events.
events(World, Events) ->
    World#world{events = Events}.
